/**
 * 
 */
package co.fitstart.admin.dao;

import java.util.List;

import co.fitstart.entity.content.Activity;
import co.fitstart.entity.content.News;

import com.demo2do.core.persistence.annotation.Dynamic;
import com.demo2do.core.persistence.annotation.Query;

/**
 * @author downpour
 *
 */
@Dynamic("hibernate")
public interface ContentDao {
    
    /**
     * list all the stick activities
     * 
     * @return
     */
    @Query("FROM Activity activity WHERE activity.serial > 100 AND activity.disabled = false ORDER BY activity.serial ASC")
    public List<Activity> listStickActivity();
    
    /**
     * list all the stick news
     * 
     * @return
     */
    @Query("FROM News news WHERE news.serial > 100 AND news.disabled = false ORDER BY news.serial ASC")
    public List<News> listStickNews();
}
